﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Home.Master" AutoEventWireup="true" CodeBehind="ViewActivity.aspx.cs" Inherits="TimeWork.time.admin.ViewActivity" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Bredcrumb" runat="server">
    <li><a href="#" class="report">Quản trị</a></li>>
    <li><a href="ListProject.aspx">Quản lý sản phẩm</a></li>>
    <li><a href="#">Chi tiết sản phẩm</a></li>>
    <li><a href="#">Công việc</a></li>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
     <form id="Form1" runat="server">
        <div class="content-project">
            <div class="left-content-project">
                <div class="project">
                <table>
                    <tr>
                        <th class="header" colspan="2">Công việc</th>
                    </tr>
                    <tr><td colspan="2" align="center">
                        <asp:Label ID="lblError" runat="server" CssClass="fail" Font-Italic="True"></asp:Label>
                        <asp:Label ID="lblID" runat="server" Visible="False"></asp:Label>
                        <asp:Label ID="lblPID" runat="server" Visible="False"></asp:Label>
                        </td></tr>
                    <tr>
                        <td style="width:90px;">Tên sản phẩm:</td>
                        <td>
                            <asp:Label ID="lblProjectName" runat="server"></asp:Label> 
                        </td>
                    </tr>
                    <tr>
                        <td>Mã công việc:</td>
                        <td>
                           
                            <asp:TextBox ID="txtActivityCode" runat="server" Width="100px"></asp:TextBox> 
                            
                        </td>
                    </tr>
                    <tr>
                        <td>Tên công việc*:</td>
                        <td>
                           
                            <asp:TextBox ID="txtActivityName" runat="server" Width="280px"></asp:TextBox> 
                            
                        </td>
                    </tr>
                    <tr>
                        <td>Thời gian dự kiến:</td>
                        <td>
                            <asp:TextBox ID="txtEstimateTime" runat="server" Width="50px"></asp:TextBox> <i>(tính bằng giờ)</i>                         
                        </td>
                    </tr>
                    <%--<tr>
                        <td>Loại thời giờ:</td>
                        <td>
                            <asp:DropDownList ID="ddlTypeTime" runat="server">
                            </asp:DropDownList>             
                        </td>
                    </tr>--%>
                    <tr>
                        <td  colspan="2" align="right">
                            <asp:Button ID="btnDelete" runat="server" Text="Xóa" 
                                CssClass="mybutton color-red" onclick="btnDelete_Click" OnClientClick="return confirm('Bạn chắc chắn muốn xóa công việc này?');" />&nbsp;&nbsp;<asp:Button 
                                ID="btnUpdate" runat="server" Text="Cập nhật" CssClass="mybutton" 
                                onclick="btnUpdate_Click" />
                        </td>
                    </tr>
                </table>
                </div>
                <br />
                <asp:Panel ID="pnlTime" runat="server">
                    <div class="project">
                    <table>
                    <tr>
                        <th class="header">Chi tiết thời gian đăng ký</th>
                    </tr>
                    <tr>
                        <asp:GridView ID="gvTime" runat="server" AutoGenerateColumns="false" 
                            onrowdatabound="gvTime_RowDataBound" ShowFooter="True">
                                <Columns>
                                    <asp:TemplateField HeaderText="Ngày tháng" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblDate" Text='<%# Bind("SADate","{0:dd/MM/yyyy}") %>'></asp:Label>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:TemplateField HeaderText="Họ tên" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblName" Text='<%# Bind("StaffName") %>'></asp:Label>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:TemplateField HeaderText="Số giờ" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91" ItemStyle-HorizontalAlign="Center" FooterStyle-HorizontalAlign="Center">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblTimeH" Text='<%# Bind("SAReportTimeHour") %>'></asp:Label>
                                        </ItemTemplate>
                                        <FooterTemplate>
                                            <asp:Label ID="lblSumHour" runat="server" Font-Bold="True" ForeColor="#990000"></asp:Label>
                                        </FooterTemplate>
                                    </asp:TemplateField>
                                    <asp:TemplateField HeaderText="Số phút" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91"  ItemStyle-HorizontalAlign="Center" FooterStyle-HorizontalAlign="Center">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblTimeM" Text='<%# Bind("SAReportTimeMinute") %>'></asp:Label>
                                        </ItemTemplate>
                                        <FooterTemplate>
                                            <asp:Label ID="lblSumMinute" runat="server" Font-Bold="True" ForeColor="#990000"></asp:Label>
                                        </FooterTemplate>
                                    </asp:TemplateField>
                                    <asp:TemplateField HeaderText="Ghi chú" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblNote" Text='<%# Bind("SADetails") %>'></asp:Label>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                </Columns>
                            </asp:GridView> 
                    </tr>
                </table>
            </div>
                </asp:Panel>
            </div>
            <div class="right-content-project">
                <asp:Panel ID="pnlProjectMember" runat="server">
                    <div class="project">
                    <table>
                        <tr>
                            <th class="header">Thời gian đăng ký theo người dùng</th>
                        </tr>
                        <tr>
                            <asp:GridView ID="gvPerUser" runat="server" AutoGenerateColumns="false">
                                <Columns>
                                    <asp:TemplateField HeaderText="Họ tên" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblName" Text='<%# Bind("StaffName") %>'></asp:Label>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:TemplateField HeaderText="Số giờ" HeaderStyle-HorizontalAlign="Center" HeaderStyle-BackColor="#f3f9ff" HeaderStyle-ForeColor="#375b91" ItemStyle-HorizontalAlign="Center">
                                        <ItemTemplate>
                                            <asp:Label runat="server" ID="lblTime" Text='<%# Bind("Time") %>'></asp:Label>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                </Columns>
                            </asp:GridView>   
                        </tr>
                    </table>
                </div>
                </asp:Panel>
                
            </div>
        </div>
     
     </form>
</asp:Content>
